package com.example.demo.listToTree;

import java.util.ArrayList;
import java.util.List;

public class Zone implements TreeNode<Zone, Long>{
    Long id;
    String name;
    Long parentId;
    List<Zone> children;

    public Zone () {
    }

    public Zone (Long id, String name, Long parentId) {
        this.id = id;
        this.name = name;
        this.parentId = parentId;
    }


    public Long getId () {
        return id;
    }

    public void setId (Long id) {
        this.id = id;
    }

    public String getName () {
        return name;
    }

    public void setName (String name) {
        this.name = name;
    }
    @Override
    public Long getParentId () {
        return parentId;
    }

    public void setParentId (Long parentId) {
        this.parentId = parentId;
    }

    @Override
    public List<Zone> getChildren () {
        return children;
    }

    @Override
    public void setChildren(List<Zone> children) {
        this.children = children;
    }
}